package com.kldaby.service;

import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Service;

@Service
public class NaiveWaiter {

    public NaiveWaiter() {
        System.out.println("create NaiveWaiter...");
    }

    public void greetTo(String name) {
        if(name == null) {
            name.equals("aaa");
//            throw new RuntimeException("name is null");
        }
        System.out.println("NaiveWaiter:greet to " + name);
    }

    public void serveTo(String clientName) {
        System.out.println("NaiveWaiter:serving "+ clientName);
    }

    public String getMessage() {
        return "买单....";
    }
}
